import { http } from './http'
import { business } from './url'

export function generateBusinessAccount() {
    const url = business.generateBusinessAcount
    return http.post(url, {})
}

export function getMemberList(params: any, page: any) {
    const url = `${business.getMemberList}?pageIndex=${page.pageIndex}&pageSize=${page.pageSize}`
    return http.post<any>(url, params)
}

export function createMember(params: any) {
    const url = business.createMember
    return http.post<any>(url, params)
}

export function getBusinessApplyRecord(params: any, page: any) {
    const url = `${business.getBusinessApplyRecord}/${page.pageIndex}/${page.pageSize}`
    return http.post<any>(url, params)
}

export function approveBusinessParter(params: any) {
    const url = business.approveBusinessParter
    return http.post<any>(url, params)
}

export function getCustomIdentifyApplyRecord(params: any, page: any) {
    const url = `${business.getCustomIdentifyApplyRecord}/${page.pageIndex}/${page.pageSize}`
    return http.post<any>(url, params)
}

export function approveCustomIdentify(params: any) {
    const url = business.approveCustomIdentify
    return http.post<any>(url, params)
}

export function isBusinessAccount() {
    const url = business.isBusinessAccount
    return http.post<any>(url, {})
}

